<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Document</title>
    <!-- 引入样式 -->
    <link rel="stylesheet" href="../public/css/reset.css">
    <link rel="stylesheet" href="../public/css/index.css">
    <style>
        html,
        body {
            width: 100%;
            height: 100%
        }

        .fr {
            float: right;
        }

        .w100 {
            width: 100%;
        }

        .h100 {
            height: 100%;
        }

        .bc {
            background-color: rgb(84, 92, 100);
        }

        .el-header {
            padding: 0;
        }
    </style>
</head>

<body>
    <div id="app" class="h100">
        <el-container class="h100">
            <el-aside width="205px" style="height: 100%;position: fixed;left: 0;top: 0;">
                <el-col class="h100">
                    <el-menu default-active="2" class="el-menu-vertical-demo h100"  active-text-color="#ffd04b"
                        style="padding-top: 65px;box-sizing: border-box;">
                        <!-- <el-submenu index="1">
                            <template slot="title">
                                <i class="el-icon-location"></i>
                                <span>所有事务</span>
                            </template>
                            <el-menu-item-group>
                                <template slot="title">分组一</template>
                                <el-menu-item index="1-1">选项1</el-menu-item>
                                <el-menu-item index="1-2">选项2</el-menu-item>
                            </el-menu-item-group>
                            <el-menu-item-group title="分组2">
                                <el-menu-item index="1-3">选项3</el-menu-item>
                            </el-menu-item-group>
                            <el-submenu index="1-4">
                                <template slot="title">选项4</template>
                                <el-menu-item index="1-4-1">选项1</el-menu-item>
                            </el-submenu>
                        </el-submenu> -->
                        <el-menu-item index="1" @click="changeItem(1)">
                            <i class="el-icon-menu"></i>
                            <span slot="title">所有事务</span>
                        </el-menu-item>
                        <el-menu-item index="2" @click="changeItem(2)">
                            <i class="el-icon-menu"></i>
                            <span slot="title">我的事务</span>
                        </el-menu-item>
                        <el-menu-item index="3" @click="changeItem(3)">
                            <i class="el-icon-document"></i>
                            <span slot="title">店铺列表</span>
                        </el-menu-item>
                        <el-menu-item index="4" @click="changeItem(4)">
                            <i class="el-icon-document"></i>
                            <span slot="title">我的客户</span>
                        </el-menu-item>
                        <el-menu-item index="5" @click="changeItem(5)">
                            <i class="el-icon-document"></i>
                            <span slot="title">业务跟踪</span>
                        </el-menu-item>
                        <el-menu-item index="6" @click="changeItem(6)">
                            <i class="el-icon-setting"></i>
                            <span slot="title">账号管理</span>
                        </el-menu-item>
                    </el-menu>
                </el-col>
            </el-aside>

            <el-container>
                <el-header class="bc w100" style="position: fixed;left: 0;top: 0;">
                    <!-- <el-radio-group v-model="isCollapse" style="margin-bottom: 20px;">
                        <el-radio-button :label="false">展开</el-radio-button>
                        <el-radio-button :label="true">收起</el-radio-button>
                    </el-radio-group> -->
                    <el-menu :default-active="activeIndex2" class="el-menu-demo fr" mode="horizontal" @select="handleSelect" background-color="#545c64"
                        text-color="#fff" active-text-color="#ffd04b">
                        <el-menu-item index="1">处理中心</el-menu-item>
                        <el-submenu index="2">
                            <template slot="title">我的工作台</template>
                            <el-menu-item index="2-1">选项1</el-menu-item>
                            <el-menu-item index="2-2">选项2</el-menu-item>
                            <el-menu-item index="2-3">选项3</el-menu-item>
                            <el-submenu index="2-4">
                                <template slot="title">选项4</template>
                                <el-menu-item index="2-4-1">选项1</el-menu-item>
                                <el-menu-item index="2-4-2">选项2</el-menu-item>
                                <el-menu-item index="2-4-3">选项3</el-menu-item>
                            </el-submenu>
                        </el-submenu>
                        <el-menu-item index="3" disabled>消息中心</el-menu-item>
                        <el-menu-item index="4">
                            <a href="https://www.ele.me" target="_blank">订单管理</a>
                        </el-menu-item>
                    </el-menu>
                </el-header>
                <el-main style="padding-left: 220px;padding-top: 65px;" class="h100">
                    <iframe :src="html_view" frameborder="0" width="100%" height="100%"></iframe>
                </el-main>
            </el-container>
        </el-container>
    </div>

</body>
<script src="../public/js/vue.js"></script>
<!-- 引入组件库 -->
<script src="../public/js/index.js"></script>
<script>
    var app = new Vue({
        el: "#app",
        data() {
            return {
                activeName: 'first',
                html_view:"all_work.html"
            }
        },
        methods:{
            changeItem(item){
                switch (item) {
                    case 1:
                        this.html_view = "all_work.html";
                        break;
                    case 2:
                        this.html_view = "my_work.html";
                        break;
                    case 3:
                        this.html_view = "shop_list.html";
                        break;
                    case 4:
                        this.html_view = "my_customer.html";
                        break;
                    case 5:
                        this.html_view = "service_trace.html";
                        break;
                    case 6:
                        this.html_view = "admin_manage.html";
                        break;                
                    default:
                        break;
                }
                
            }
        }
    })
</script>

</html>